/**
 * Created by zhangz on 2017/5/25.
 */
import {Component, Inject}   from '@angular/core';
import { HeroService} from  '../service/hero.service';
import {Hero} from "../model/hero";
import {Logger} from "../service/logger.service";
// import {AppConfig, APP_CONFIG} from "../config/app-config";
@Component({
    selector: 'hero-list',
    providers: [HeroService, Logger],
    template: `
  <div *ngFor="let hero of heroes" >
    {{hero.id}} - {{hero.name}}
  </div>
  `
})
export class HeroListComponent {
    heroes: Hero[];
    test: any;
    tData: any;
    // constructor(heroService: HeroService, ) {
    //     this.heroes = heroService.getHeroes();
    //     // this.test = config.apiEndpoint;
    //     // this.tData = config.title
    //     this.tData = heroService.search('2');
    // }
    // testConsole = function(){
    //     console.log(this.test);
    // };
}
